<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>AJAX.OOP Test 01</title>
<script type="text/javascript" src="../ajaxoop.js"></script>
</head>
<body>

<script type="text/javascript">
var Base = Ajax.Class({

	x : 1,
	y : 2,

	constructor : function( x, y) {
		this.x = x;
		this.y = y;
		$d.writeln( 'Base::constructor() called!');
	},
	
	add : function() {
		return (this.x + this.y);
	},
	
	display : function() {
		$d.writeln( this.add());
	}

});

var Multi = Ajax.Class( Base, {

	constructor : function() {
		this.$parent.constructor( 3, 4);
		$d.writeln( 'Multi::constructor() called!');
	},
	
	multiply : function() {
		return (this.x * this.y);
	},
	
	display : function() {
		this.$parent.display();
		$d.writeln( this.multiply());
	}

});

$d.writeln( '<pre>');

var obj = new Multi;
obj.display();

$d.writeln( '</pre>');
</script>

</body>
</html>